import { useEffect, useState } from "react";
import { useNavigate, useParams } from "react-router-dom";
import axios from "axios";
import {   NavBar,  } from "antd-mobile";
// 详情页面
const Detail = () => {
  const { id } = useParams();
  const [v, setV] = useState({});
  const navigate = useNavigate();
  console.log(id);
  const getData = async () => {
    const resp = await axios.get("/trip/train/detail", { params: { id } });
    console.log(resp);
    
    setV(resp.data.data);
  };
  useEffect(() => {
    getData();
  }, [])
  return (
    <div>
      <NavBar>详情</NavBar>
     

    </div>
  );
};

export default Detail;
